-
Notifications
You must be signed in to change notification settings - Fork 47
Add visualization tool for topology cli #369
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
4a212bf to
3f08f03
Compare
| str: ASCII visualization of the topology. | ||
| """ | ||
|
|
||
| if self.topo_type == TopologyType.BLOCK: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
When you have extremely big if else blocks-- its always best to condense them into functions.
if self.topo_type == TopologyType.BLOCK:
visualize_block_topology()
else:
# assuming tree
visualize_tree_topology()
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It would also be nice if visualize_topology* functions actually get moved to util since its not really part of core topology logic. You also dont really need any data from the topology class. Just the string and the block size. Thats an optional suggestion though.
3f08f03 to
14d5ba0
Compare
14d5ba0 to
8d018cb
Compare
Add visualization tool for topology cli to create ASCII art to visualize block and tree slurm topologies
visualizefunction toTopologyclassrunfunction now returns the topology string sovisualizefunction can take it in to generate the visualizationExample Block topology visual:
Example Block topology visualization with nodes less than max_block_size
Example Block Topology visual with block with nodes less than min block size
Example Tree topology visual: